<template>
	<view>
		<view class="imgStyle">
			<image :src="item.image" mode="aspectFill" style="width: 100%;">
		</view>
		<view class="shop-detail">
			<view class="text">{{item.name}}</view>
			<view class="inventory">库存 {{item.inventory}}</view>
			<!-- <view class="price">
				<span class="now"><span style="font-size: 20rpx;">￥</span>{{item.price}}</span>
				<span class="old" v-show="item.oldPrice">￥{{item.oldPrice}}</span>
			</view> -->
		</view>
	</view>
</template>

<script>
	export default {
		props: {
			item: Object,
		}
	}
</script>

<style scoped lang="scss">
	.imgStyle {
		width: 100%;
		height: 400rpx;
		overflow: hidden;
	}

	.shop-detail {
		margin: 12rpx 0;
		padding:24rpx;

		.text {
			font-weight: 500;
			font-size: 40rpx;
			color: #333333;
		}

		.inventory {
			font-size: 32rpx;
			padding: 12rpx 0;
			color: #999;
		}

		.item-contorl {
			display: flex;
			margin-top: 24rpx;

			.price {
				line-height: 24px;
				flex: 1;

				.now {
					margin-right: 8px;
					font-size: 16px;
					color: #ff6506;
					font-weight: 500;
				}

				.old {
					text-decoration: line-through;
					font-size: 12px;
					color: #999;
				}
			}
		}
	}
</style>